package cc.kzc.adminauth.ds1.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.Comment;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import lombok.Data;

@Entity
@Table(name = "t_permission")
@DynamicUpdate(true)
@DynamicInsert(true)
@Data
public class PermissionEO implements Serializable {
	private static final long serialVersionUID = -6502489433377664806L;

//	{
//      "authorityId": 3,
//      "authorityName": "查询用户",
//      "orderNumber": 3,
//      "menuUrl": "",
//      "menuIcon": "",
//      "createTime": "2018/07/21 13:54:16",
//      "authority": "user:view",
//      "checked": 0,
//      "updateTime": "2018/07/21 13:54:16",
//      "isMenu": 1,
//      "parentId": 2
//    }

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name = "f_id")
	@Comment("权限id")
	private Long id;

	@Column(name = "f_authority")
	@Comment("权限标识")
	private String authority;
	
	@Column(name = "f_authority_name")
	@Comment("权限名称")
	private String authorityName;

	@Column(name = "f_be_menu")
	@Comment("是否菜单。0为菜单。1为按钮。")
	private Integer beMenu;

	@Column(name = "f_menu_url")
	@Comment("菜单url")
	private String menuUrl;

	@Column(name = "f_menu_icon")
	@Comment("菜单图标")
	private String menuIcon;

	@Column(name = "f_order_number")
	@Comment("排序号")
	private Integer orderNumber;

	@Column(name = "f_parent_id")
	@Comment("父权限id")
	private Long parentId;

	@Column(name = "f_ctime")
	@Comment("创建时间")
	private String ctime;

	@Column(name = "f_mtime")
	@Comment("修改时间")
	private String mtime;

}
